﻿using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.Text;

namespace Qianke.Core.Common
{
    [AttributeUsage(AttributeTargets.Class)]
    public class ServiceKeyNameAttribute : Attribute
    {
        public string Name { set; get; }


        public ServiceLifetime Lifetime { set; get; }


        public Type InfaceType { set; get; }


        public ServiceKeyNameAttribute(string name, Type infaceType, ServiceLifetime lifetime =  ServiceLifetime.Scoped)
        {
            this.Name = name;
            this.Lifetime = lifetime;
            this.InfaceType = infaceType;
        }
    }
}
